<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jstl/core"%>    
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Insert title here</title>
<link href="./css/style.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" language="javascript">
<!--
	function checkForm(){
		var actionCode = document.getElementById("actionCode");
		var actionName = document.getElementById("actionName");
		
		if(actionCode.value == ""){
			alert("操作编码不能为空！");
			return false;
		}
		if(actionName.value == ""){
			alert("操作名称不能为空！");
			return false;
		}
		return true;
	}

	function back(){
		window.location.href = "./function.do";
		window.location.target = "main";
	}
	
	function save(){
		if(checkForm()){
			document.addActionForm.action = "./action.do?action=addAction";
			document.addActionForm.target = "main";
			document.addActionForm.submit();
		}
	}
-->
</script>
</head>
<body>
<form name="addActionForm" action="" method="post">
	<a class="common_title">>> 您现在的位置：基础设置 >> 新增操作</a>
	
	<div class="tools">
		<a class="save" href="javascript:save();" title="保存" hidefocus="true">保存</a>&nbsp;&nbsp;
		<a class="back" href="javascript:back();" title="返回" hidefocus="true">返回</a>&nbsp;&nbsp;
	</div>
	
	<table class="table_input1" height="30" cellpadding="0" cellspacing="0">
		<tr>
			<td width="15%">&nbsp;&nbsp;操作编码：<input id="functionId" name="functionId" type="hidden" value="${functionId}"/></td>
			<td><input id="actionCode" name="actionCode" class="input1" type="text"/></td>
			<td width="18%">操作名称：</td>
			<td><input id="actionName" name="actionName" class="input1" type="text"/></td>
		</tr>
	</table><br>
	
	<table class="table_style" style="text-align: center;">
		<tr>
			<td class="title" width="10%">序号</td>
			<td class="title">操作编码</td>
			<td class="title">操作名称</td>
			<td class="title">是否有效</td>
			<td class="title">操作</td>
		</tr>
		<c:forEach var="action1" items="${actions}">
		<tr>
			<td>1</td>
			<td>${action1.actionCode}</td>
			<td>${action1.actionName}</td>
			<td>是</td>
			<td>
				<img class="btn_img" src="./images/a_del.gif" onclick="" title="删除">&nbsp;&nbsp;
			</td>
		</tr>
		</c:forEach>
	</table>
</form>
</body>
</html>